package com.yuerenjf.yuerenjinfu;

import android.app.Application;
import android.content.Context;

import com.nostra13.universalimageloader.core.ImageLoader;
import com.nostra13.universalimageloader.core.ImageLoaderConfiguration;
import com.tencent.smtt.sdk.QbSdk;
import com.umeng.socialize.PlatformConfig;
import com.umeng.socialize.UMShareAPI;
import com.yuerenjf.yuerenjinfu.http.HttpGetToken;

import org.xutils.x;

//import com.umeng.socialize.PlatformConfig;

/**
 * Created by ntop on 15/7/8.
 */
public class MyApplication extends Application {
    public static Context CONTEXT;
//    private PushAgent mPushAgent;


    @Override
    public void onCreate() {
        super.onCreate();
        setContext(this);
//        mPushAgent = PushAgent.getInstance(this);
        x.Ext.init(this);
        x.Ext.setDebug(true);
        UMShareAPI.get(this);
        PlatformConfig.setWeixin("wxccd8f992d7f2a572","e4145e34141f2ba47a2e29e07353cc29");
        PlatformConfig.setQQZone("101416680","4e9435d01685204aed8ddefe513dd136");
        //创建默认的ImageLoader配置参数
        ImageLoaderConfiguration configuration = ImageLoaderConfiguration
                .createDefault(this);

        //Initialize ImageLoader with configuration.
        ImageLoader.getInstance().init(configuration);
//        JPushInterface.init(this);

        QbSdk.initX5Environment(CONTEXT,null);


        HttpGetToken.getToken(CONTEXT);



    }
    private static void setContext(Context mContext) {
        CONTEXT = mContext;
    }

    public static Context getContext() {
        return CONTEXT;
    }


}
